package com.jr9z.jrjz.service;

import com.jr9z.jrjz.entity.MinistryCase;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @Author:Mrzhang
 * @Description:服务案例service
 * @Date:2019.03.25 21:41
 **/
public interface MinistryCaseService {

    int deleteByPrimaryKey(Integer caseId);

    int insert(MinistryCase record);

    int insertSelective(MinistryCase record);

    MinistryCase selectByPrimaryKey(Integer caseId);

    int updateByPrimaryKeySelective(MinistryCase record);

    int updateByPrimaryKeyWithBLOBs(MinistryCase record);

    int updateByPrimaryKey(MinistryCase record);

    /**
     * @Description:查询某一服务类型下面的案例列表
     * @date: 11:05 2019-4-1
     * @param: serviceId  服务类型id
     * @return: 服务案例列表
     */
    List<MinistryCase> getMinistryCaseByServiceId(Integer serviceId);

    /**
     * @Description:查询某一服务类型下的案例数量
     * @date: 11:34 2019-4-1
     * @param: serviceId 服务案例id
     * @return: java.lang.Long
     */
    Long getServiceCaseByServiceId(Integer serviceId);

    /**
     * 上移
     *
     * @param serviceId
     * @return
     */
    void moveUp(Integer caseId, Integer serviceId);

    /**
     * 下移
     *
     * @param serviceId
     */
    void moveDown(Integer caseId, Integer serviceId);


    MinistryCase getPrev(Integer caseId, Integer serviceId);


    MinistryCase getNext(Integer caseId, Integer serviceId);


}
